package com.esun.payment_api.service.impl;

import com.esun.payment_api.bean.PjBean;
import com.esun.payment_api.bean.SumDkReceiveMoneyBean;
import com.esun.payment_api.dto.PInvInsParam;
import com.esun.payment_api.dto.PjQueryParam;
import com.esun.payment_api.mapper.FkDraftClaimMapper;
import com.esun.payment_api.service.FkDraftClaimService;
import com.github.pagehelper.PageHelper;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class FkDraftClaimServiceImpl implements FkDraftClaimService {

    @Resource
    private FkDraftClaimMapper fkDraftClaimMapper;

    @Override
    public int deleteById(Integer id) {
        return fkDraftClaimMapper.deleteById(id);
    }

    @Override
    public void insertMultiple(PInvInsParam param) {
        fkDraftClaimMapper.pFkInsClaim(param);
    }

    @Override
    public List<PjBean> getFkSelectPjList(PjQueryParam queryParam, Integer pageSize, Integer pageNum) {
        PageHelper.startPage(pageNum, pageSize);
        return fkDraftClaimMapper.getFkSelectPjList(queryParam);
    }

    @Override
    public SumDkReceiveMoneyBean getFkSelectPjZje(PjQueryParam queryParam) {
        return fkDraftClaimMapper.getFkSelectPjZje(queryParam);
    }

    @Override
    public int confirmButton(Integer id) {
        return fkDraftClaimMapper.confirmButton(id);
    }

    @Override
    public int cancelButton(Integer id) {
        return fkDraftClaimMapper.cancelButton(id);
    }
}
